/**
 * @author Linrui
 * @since 2011-06-10
 * 校园 业务接口实现类
 */
package com.qeado.colleage.service.implement;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.qeado.colleage.dao.ColleageDao;
import com.qeado.colleage.model.Colleage;
import com.qeado.colleage.service.ColleageService;
import com.qeado.user.model.User;
import com.qeado.util.FileUpload;
import com.qeado.util.PageHelper;

@Service
public class ColleageServiceImplement implements ColleageService {

	@Autowired
	private ColleageDao colleageDao;
	
	public PageHelper listAll(int pageNum, int pageSize, String type,
			String orderBy, String asc) {
		return colleageDao.listAll(pageNum, pageSize, type, orderBy, asc);
	}

	public PageHelper listByKey(int pageNum, int pageSize, String type,
			String orderBy, String asc, String key , String level) {
		key = key.trim();
		key = "%" + key + "%";
		return colleageDao.listByKey(pageNum, pageSize, type, orderBy, asc, key , level);
	}

	public Colleage queryById(String id) {
		return colleageDao.queryById(id);
	}

	public String insertColleage(Colleage colleage, FileUpload upload, User user) {
		// TODO Auto-generated method stub
		return null;
	}

	public String insertColleage(Colleage colleage, User user) {
		// TODO Auto-generated method stub
		return null;
	}

	public boolean updateColleage(Colleage colleage) {
		// TODO Auto-generated method stub
		return false;
	}

	public boolean updateColleage(Colleage colleage, FileUpload upload) {
		// TODO Auto-generated method stub
		return false;
	}

	public boolean deleteColleage(String id) {
		return colleageDao.deleteColleage(id);
	}

}
